Skip to content

Latest commit

 

History

History
23 lines (14 loc) · 782 Bytes

File metadata and controls

23 lines (14 loc) · 782 Bytes

Test Tautology

Definition:

  • Generally speaking one does not want to duplicate the logic between tests and code. So replicating a regexp or something else in the test is not an option.

Code Example:

Assertions.assertThat(processTemplate("param1", "param2")).isEqualTo(String.format("this is '%s', and this is '%s'", param1, param2));

References:

Quality attributes